package com.jbl.te.controller;


import com.jbl.commonutils.R;
import com.jbl.te.service.SchoolService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author jbl
 * @since 2020-12-10
 */
@RestController
@CrossOrigin
@RequestMapping("/te/school")
public class SchoolController {
    @Autowired
    private SchoolService schoolService;

    @GetMapping("/getAllSchool")
    @ApiOperation("获取所有学院")
    public R getAllCollege() {
        return R.ok().data("list",schoolService.list());
    }
}

